package com.yourenbang.lingyun.transaction.web.domain.vo;

import com.alibaba.fastjson.annotation.JSONField;
import com.yourenbang.lingyun.core.util.StringUtils;
import com.yourenbang.lingyun.core.util.json.ToJSON;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * <h3>service-transaction</h3>
 * <p>余额明细返回</p>
 *
 * @author : jason
 * @date : 2020-08-26 14:57
 **/
@Data
public class BalanceListVO implements Serializable, ToJSON {

    public static final String STATUSDESC_SUCC = "成功";
    public static final String STATUSDESC_FAIL = "失败";
    public static final String STATUSDESC_WAIT = "待入账";

    private Integer fundBillId;
    /**
     * 类型
     */
    private Short type;
    /**
     * 类型名称
     */
    private String typeName;
    /**
     * 返现人
     */
    private String fromName = StringUtils.EMPTY;
    /**
     * 变动金额，区分正负
     */
    private BigDecimal amount;
    /**
     * 关联订单号
     */
    private String orderId;
    /**
     * 描述，展示给用户看
     */
    private String detail;
    /**
     * 状态描述
     */
    private String statusDesc = STATUSDESC_SUCC;

    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    /**
     * 提现完成时间
     */
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime successTime;

    /**
     * 用于显示的余额
     */
    private BigDecimal balance;
    /**
     * 此次变动后的可提余额
     */
    private BigDecimal afterWithdrawAble;
    /**
     * 此次变动后的冻结金额
     */
    private BigDecimal afterFrozen;
    /**
     * 变动计划ID
     */
    private Integer fundAccountChangePlanId;
    /**
     * 账户ID
     */
    private Integer fundAccountId;

    /**
     * 机具号
     */
    private String terminalSn;

    /**
     * 机具归属人姓名
     */
    private String terminalAllyUserName;

    /**
     * 产品名称
     */
    private String channelName;

}
